import React, { Component } from 'react';
import { Text, View, Button } from 'react-native';
import { createStackNavigator, createAppContainer, NavigationActions } from 'react-navigation'
import AnimationPage from './Animation'
import ListTwoPage from './ListTwo'
import ListThreePage from './ListThree'
import ListFourPage from './ListFour'
import ListFivePage from './ListFive'
import ListPage from './List'

class HomePage extends React.Component {

  _gotoListPage(){

  }

  render() {
    return (
      <View style={{alignItems: 'center', margin:50}}>
        <Button
          onPress={()=>{this.props.navigation.navigate('AnimationPage')}}
          title="动画页面"
        />
        <Button
            onPress={()=>{this.props.navigation.navigate('ListPage')}}
            title="列表页面"
          />
        <Button
            onPress={()=>{this.props.navigation.navigate('ListTwoPage')}}
            title="列表2页面"
            />
        <Button
            onPress={()=>{this.props.navigation.navigate('ListThreePage')}}
            title="列表3页面"
              />
      </View>
    );
  }
}

const AppNavigator = createStackNavigator({
  Home: {
    screen: HomePage
  },
  AnimationPage:{
    screen:AnimationPage
  },
  ListPage:{
    screen:ListPage
  },
  ListFivePage:{
    screen:ListFivePage
  },
  ListTwoPage:{
    screen:ListTwoPage
  },
  ListThreePage:{
    screen:ListThreePage
  },
  ListFourPage:{
    screen:ListFourPage
  }
});

export default createAppContainer(AppNavigator);
